package com.example.demo.ai.llm.service;

import org.noear.solon.annotation.Component;
import org.noear.solon.flow.ChainContext;
import org.noear.solon.flow.Node;
import org.noear.solon.flow.TaskComponent;

/**
 * @author airhead
 */
@Component("helloTask")
public class HelloTask implements TaskComponent {
  @Override
  public void run(ChainContext context, Node node) throws Throwable {
    String prompt = context.get("prompt");
    System.out.printf("hello %s!\n", prompt);
  }
}
